import Vue from 'vue'
import vueRouter from 'vue-router'
// 引入组件
import my from '@/components/01-路由显示/my'
import home from '@/components/01-路由显示/home'
import order from '@/components/01-路由显示/order'
import classify from '@/components/01-路由显示/classify'
import notfund from '@/components/404'
// 使用
Vue.use(vueRouter)
//路由实例
const route = new vueRouter({
    routes:[
        {
            path:'/',
            redirect: '/home'
        },
        {
            path: '/home',
            component:home 
        },  
        {
            path: '/classify',
            component:classify 
        },  
        {
            path: '/order',
            component:order 
        },
        {
            path: '/my',
            component:my 
        },
        {
            path: '*',
            component: notfund
        }
    ]
})
export default route

